#pragma once

#include "../umlmodel_global.h"

#include "UMLDiagram.h"
#include "UMLNavigabilityNotationKind.h"

namespace uml {

/// <summary>
/// UMLDiagramWithAssociations
/// Specifies the common aspects of diagrams that show associations.
/// </summary>
class UMLMODEL_EXPORT UMLDiagramWithAssociations : public UMLDiagram {

public: // Constructors and destructors
    explicit UMLDiagramWithAssociations(const QString& umlType="uml::UMLDiagramWithAssociations");

public: // JsonSerializable override
    void fromJson(const QJsonObject& json, QStringList& errorList) override;
    void toJson(QJsonObject& json) override;

public: // Properties
    /// <summary>
    /// isAssociationDotShown getter
    /// Indicates whether dot notation for associations shall be used.
    /// </summary>
    bool isAssociationDotShown() const;

    /// <summary>
    /// isAssociationDotShown setter
    /// Indicates whether dot notation for associations shall be used.
    /// </summary>
    void setIsAssociationDotShown(bool value);

    /// <summary>
    /// navigabilityNotation getter
    /// Indicates when to show navigability of associations or connectors typed by
    /// associations.
    /// </summary>
    UMLNavigabilityNotationKind navigabilityNotation() const;

    /// <summary>
    /// navigabilityNotation setter
    /// Indicates when to show navigability of associations or connectors typed by
    /// associations.
    /// </summary>
    void setNavigabilityNotation(UMLNavigabilityNotationKind value);

    /// <summary>
    /// nonNavigabilityNotation getter
    /// Indicates when to show non-navigability of associations or connectors typed by
    /// associations.
    /// </summary>
    UMLNavigabilityNotationKind nonNavigabilityNotation() const;

    /// <summary>
    /// nonNavigabilityNotation setter
    /// Indicates when to show non-navigability of associations or connectors typed by
    /// associations.
    /// </summary>
    void setNonNavigabilityNotation(UMLNavigabilityNotationKind value);

private: // Fields
    /// <summary>
    /// isAssociationDotShown
    /// Indicates whether dot notation for associations shall be used.
    /// </summary>
    const static bool isAssociationDotShown_default_;
    bool isAssociationDotShown_= isAssociationDotShown_default_;

    /// <summary>
    /// navigabilityNotation
    /// Indicates when to show navigability of associations or connectors typed by
    /// associations.
    /// </summary>
    UMLNavigabilityNotationKind navigabilityNotation_ = UMLNavigabilityNotationKind::koneWay;

    /// <summary>
    /// nonNavigabilityNotation
    /// Indicates when to show non-navigability of associations or connectors typed by
    /// associations.
    /// </summary>
    UMLNavigabilityNotationKind nonNavigabilityNotation_ = UMLNavigabilityNotationKind::knever;

};

} // namespace uml
